<?php
    $serverpath=$_SERVER['DOCUMENT_ROOT'];
    //include_once ($serverpath.'/Classes/book.php');
	$section=$_POST['select'];
	$filename=$serverpath."/files/Section/".$section.".txt";
	$fp = fopen($filename, "r");
	while (!feof($fp)) {
		$arreglo[]=fgets($fp);
	}
	fclose($fp);
	$serialize_search = serialize($arreglo);
	file_put_contents('store_search',$serialize_search);
	
	header ('Location: searchResult.php');
?>